<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
    <head>
        <script>
            // function f(age){
            //     var v=age.value;
            //     var reg=/^\d+$/;
            //     if(reg.test(v)){
            //         console.log("1");
            //         document.getElementById("sub").disabled="";
            //     }else{
            //         console.log("0");
            //         document.getElementById("sub").disabled="disabled";
            //     }
            // }
        </script>
    </head>
    <body>
        ${requestScope.user}
        <form action="${pageContext.request.contextPath}/user/submit" method="post">
            用户名：<input type="text" name="username" value="${user.username}"/><br/>
            密码：<input type="password" name="password" value="${user.password}"/><br/>
            电话：<input type="text" name="phone" value="${user.phone}"/><br/>
            年龄：<input type="text" name="age" value="${user.age}"/><br/>
            <input id="sub" type="submit" value="提交"/>
        </form>
    </body>
</html>
